package com.horoscope.astrology.zodiac.signs.free.bean

import java.io.Serializable

class CityResultBean : BaseBean() {
    var geonames = ArrayList<CityInfo>()
}

class CityInfo() : Serializable {
    var timezone = TimeZone()
    var name = ""
    var countryName = ""
    var adminName1 = ""
    var bbox = BBox()


    inner class BBox() : Serializable {
        var north = ""
        var west = ""
    }

    inner class TimeZone() : Serializable {
        var gmtOffset = 0
        val timeZoneId = ""
    }

    override fun equals(other: Any?): Boolean {
        if (this === other) return true
        if (javaClass != other?.javaClass) return false

        other as CityInfo

        if (timezone != other.timezone) return false
        if (name != other.name) return false
        if (countryName != other.countryName) return false
        if (adminName1 != other.adminName1) return false
        if (bbox != other.bbox) return false

        return true
    }

    override fun hashCode(): Int {
        var result = timezone.hashCode()
        result = 31 * result + name.hashCode()
        result = 31 * result + countryName.hashCode()
        result = 31 * result + adminName1.hashCode()
        result = 31 * result + bbox.hashCode()
        return result
    }
}